package com.example.Vehcile;

public class Vehicle {

    private String name;

    private String color;
    private int age;
    private double price;

    public Vehicle(String name, String color, int age, double price) {
        this.name = name;
        this.color = color;
        this.age = age;
        this.price = price;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public void drive(){
        System.out.println("交通工具可以驾驶");
    }

    public void stop(){
        System.out.println("交通工具可以停下来");
    }
}
